Conversation
…onsole-log Remove debug console.log from toolbar play handler
chore: remove debug console statements from js/palette.js
… Context Menu (sugarlabs#5599) * Manage click listeners to prevent duplicates * Forgot to Close trashViewClickHandler function
* fix(graphics): add SVG output support for Bezier curves * fix(svg): start bezier path at turtle position to preserve initial tangent * fix: svg output tally with shown output * formatting code
…ics (sugarlabs#5606) * fix: replace loose equality operators with strict equality in SaveInterface.js and block.js * fix: use strict equality where behavior is unchanged
…abs#5642) * fix: resolve initialization crashes and loading screen issues - Restore missing createArtwork method in turtles.js that was causing TypeError during turtle initialization - Add guard clause in doSearch to prevent crash when searchWidget is undefined - Add robust null checks in showContents to prevent crashes on missing DOM elements and ensure loading screen is properly hidden - Add RequireJS shim for constraints.js to depend on interface.js, fixing 'JSInterface is not defined' ReferenceError - Add safe fallback for DEFAULTVOLUME in turtle-singer.js to handle module loading order issues These fixes address race conditions and missing methods that were preventing the application from fully loading and causing the 'Combining math and music...' loading screen to persist. * style: format files with prettier * fix(playback): resolve turtle cache infinite loop and missing bpm constant * style: fix formatting in js files
…garlabs#5575) * Remove tuner test helper functions Remove the testTuner and testSpecificFrequency methods from the Synth() class. The helper functions of these tests create an audio context, oscillator, and gain node to play the test frequencies for verification of the manual tuner. This is more for ad-hoc tests rather than runtime. * Add tuner AudioContext tests; remove debug logs
This PR fixes a UI state inconsistency where the Stop button failed to update its visual state (turning red) when music playback was initiated using the Space key.
…overage test: add unit tests for p5-adapter factory and window bindings
…y-debug-console-log fix: remove debug console.log from KeySignatureEnv initialization
…asic-coverage test: add tuner and sample preload edge case coverage for synthutils
…-message-scope test: Enhance error scope validation in AST2BlockList tests
…tests test: add unit tests for Reflection widget
…Manager-tests Add IndexedDB integration tests for Planet CacheManager.js
The crescendo end listener pops crescendoDelta and crescendoInitialVolume but never pops inCrescendo, causing it to grow unboundedly and trigger spurious volume resets on subsequent notes. Signed-off-by: Ady0333 <adityashinde1525@gmail.com>
…arlabs#5929) * fix: reduce canvas and bitmap memory by lazy-caching grids and shrinking scroll buffer - Remove eager bitmap.cache() from _createGrid() — 8 grids were each allocating a 1200x900x4 (~4.3 MB) backing canvas at startup even though at most 1 grid is visible at a time (~35 MB wasted) - Add cache(0,0,1200,900) in _show*() methods so grids are only cached when made visible, and uncache() in _hide*() to free the backing canvas immediately when hidden - Skip trashed blocks in clearCache() to avoid re-creating backing canvases for invisible blocks on every theme/resize event - Uncache trashed block containers in sendStackToTrash() and delete their blockArt/blockCollapseArt SVG strings to free memory - Cap trashStacks undo history at 100 entries to prevent unbounded growth during long editing sessions - Reduce scroll canvas from 3x to 2x viewport dimensions in doScrollXY(), saving ~40 MB at 1920x1080 (75 MB -> 33 MB) - Update scroll boundary clamps to match the new 2x canvas size Estimated RAM savings: ~70-120 MB depending on viewport size and number of trashed blocks. * fix: stop calling updateCache() on uncached accidental bitmaps — fixes grid display * fix: guard updateCache() for uncached blocks and re-cache on restore from trash
…oad-coverage Test: Improve boundary.js coverage – image onload callback
- Add PR Category section to PR template with 5 categories (Bug Fix, Feature, Performance, Tests, Documentation) - Add GitHub Actions workflow that validates PR category selection - Auto-apply matching repo labels (Issue-Bug, Issue-Enhancement, Issue-Performance, Issue-Testing, Issue-Documentation) - Auto-remove labels when categories are unchecked - Uses pull_request_target for fork PR compatibility
|
Caution Review failedThe pull request is closed. ℹ️ Recent review infoRun configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (10)
📒 Files selected for processing (142)
📝 WalkthroughWalkthroughThis pull request introduces substantial enhancements across multiple systems: GitHub Actions workflows for PR validation and E2E testing, PWA support with install prompts, ActivityContext singleton for centralized activity management, comprehensive test coverage expansion, async/fetch-based HTTP handling, keyboard navigation in the toolbar, audio voice tracking improvements, block system refactoring with metadata caching, SVG/Bezier rendering enhancements, and responsive pie menu sizing. Documentation updates include contributing guidelines and production build strategy. CSS improvements address accessibility (focus-visible) and dark mode styling. Changes
Sequence Diagram(s)sequenceDiagram
participant Client as Client/Browser
participant GitHub as GitHub Actions
participant PR as Pull Request
participant Workflow as Category Check Workflow
participant API as GitHub REST API
Client->>GitHub: Push/Open PR with body containing checkboxes
GitHub->>Workflow: Trigger pr_category_check on pull_request_target
Workflow->>PR: Parse PR body via regex
Note over Workflow: Extract checked categories<br/>(Issue-Bug, Issue-Enhancement, etc.)
alt No categories matched
Workflow->>API: FAIL workflow with error table
API-->>Client: PR Check Failed
else Categories matched
Workflow->>API: GET current PR labels
Workflow->>Workflow: Compute labelsToAdd & labelsToRemove
Workflow->>API: Add missing labels
Workflow->>API: Remove unchecked labels
Note over API: Per-label error handling<br/>(warn if label not in repo)
API-->>Client: PR Check Passed + Labels Synced
Workflow->>Workflow: Log selected categories & synced labels
end
sequenceDiagram
participant User as User/Browser
participant Activity as Activity Module
participant Context as ActivityContext Singleton
participant Window as window (deprecated)
User->>Activity: Initialize Activity
Activity->>Context: setActivity(this)
Context->>Context: Store activity reference
Note over Context: Freeze public API<br/>(prevent overrides)
User->>Context: Call getActivity()
Context-->>User: Return stored activity
User->>Window: Access deprecated window.activity
Window->>Window: Deprecation guard IIFE
Note over Window: console.warn:<br/>Use ActivityContext.getActivity()
Window-->>User: undefined (not persisted)
User->>Window: Assign window.activity = newVal
Window->>Window: Deprecation guard IIFE
Note over Window: console.error:<br/>Use ActivityContext.setActivity()
Window-->>User: Assignment blocked
sequenceDiagram
participant User as User
participant Toolbar as Toolbar UI
participant Handler as Keyboard Handler
participant DOM as DOM/Elements
participant Modal as Modal/Dropdown
User->>Toolbar: Press ArrowRight/ArrowDown
Toolbar->>Handler: setupKeyboardNavigation()
Handler->>DOM: Discover focusable buttons
Handler->>DOM: Find spatial neighbors
Note over Handler: Proximity heuristics for<br/>vertical/horizontal navigation
Handler->>DOM: Apply toolbar-btn-focused class
Handler->>DOM: Update tabindex & focus
DOM-->>User: Visual focus indicator
User->>Toolbar: Press Enter on button
Handler->>Modal: Check if dropdown/regular
alt Regular Button
Handler->>Modal: Invoke button action
Handler->>Toolbar: Auto-refocus after action
else Dropdown
Handler->>Modal: Open dropdown menu
Modal->>DOM: Show items
Handler->>DOM: Apply dropdown-item-focused
User->>Modal: Navigate items with Arrow keys
User->>Modal: Press Enter to select
Handler->>Modal: Close dropdown
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~75 minutes Poem
✨ Finishing Touches
🧪 Generate unit tests (beta)
|
|
✅ All Jest tests passed! This PR is ready to merge. |
Summary by CodeRabbit
Release Notes
New Features
Bug Fixes
Documentation
Tests